<?php
namespace app\hsycms\model;
use think\Db;
use think\Model;

/**
 * 文章模型
 */
class Article extends Model
{
  
	//百度推送
	public function baiduPush($aid,$nid){		
		$result = baiduPushUrl($aid,$nid);
		$result = json_decode($result,true);
		if($result['success']=="1"){
			$info = '添加成功,URL已推送至百度';
		}else{
			$info = '添加成功,<br/>URL推送失败error:'.$result['error'].',message:'.$result['message'];
		}
		return $info;
	}
		
}